/*
 * UnaryExpressionDescription.java
 * 
 * last update: 16.01.2010 by Stefan Saru
 * 
 * author:	?
 * 
 * Obs:
 */
package engine;

@SuppressWarnings("serial")
class UnaryExpressionDescription implements ExpressionDescription{

	ExpressionDescription exp;
	String op;

	UnaryExpressionDescription(String op, ExpressionDescription exp){
		this.exp = exp;
		this.op = op;
	}

	public Expression instantiate(NameSpace ns)throws ParseException{
		return new UnaryExpression(ns, op, exp.instantiate(ns));
	}

	public boolean isLeftValue(){
		return true;
	}

	public String toString(){
		return " " + op + " " + exp;
	}
}









